package com.baby.movie.app.ui;

import android.app.Activity;
import android.content.Intent;
import android.os.Bundle;
import android.widget.ImageView;

import com.baby.movie.R;

public class WelcomeActivity extends Activity {
	
	private static final int DELAY = 1000;
	
	private ImageView mIvBackground;
	
	@Override
	protected void onCreate(Bundle savedInstanceState) {
		super.onCreate(savedInstanceState);
		setContentView(R.layout.activity_welcome);
		
		mIvBackground = (ImageView) findViewById(R.id.ivBackground);
		mIvBackground.postDelayed(new Runnable() {
			
			@Override
			public void run() {
				showMain();
			}
		}, DELAY);
	}
	
	private void showMain() {
		Intent intent = new Intent(this, MainActivity.class);
		startActivity(intent);
		finish();
	}
}
